package com.my.study.controller;

import com.my.study.utils.IOUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * http://localhost:8080/test/
 *
 * @author: yidujun
 * @create: 2021/05/12 16:51
 */
@RequestMapping("/test")
@RestController
@Slf4j
public class TestController {

    @RequestMapping("/testIOUtil")
    public String testIOUtil() throws Exception {
        String path = "mybatis/mybatis-config.xml";
        String read = IOUtil.read(path, "UTF-8");
        log.info("read: [{}]", read);
        return read;
    }


}
